package pack0916;

// 练习1：求出1/1+1/2+1/3+1/4+…+1/10之和。
public class DemoH {
    public static void main(String[] args) {
        double sum = 0;
        for (double i = 1; i < 11; i++) {
            sum = sum + 1 / i;
        }
        System.out.println(sum);
    }
}